package com.zy.business.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.zy.business.domain.TbDailyReport;
import com.zy.business.domain.TbDailyReportAnnotate;
import com.zy.business.domain.TbUserDailyReport;
import com.zy.common.core.domain.entity.SysUser;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 日报 Mapper 接口
 */
public interface DailyReportMapper extends BaseMapper<TbDailyReport> {

    List<TbDailyReport> getReportByDate(Long reportId);

    List<TbUserDailyReport> selectReportList(@Param("user") SysUser user, @Param("reportDate") String reportDate);

    Map<String, Object> selectUserWorkHour(@Param("userName") String userName, @Param("projectId") Long projectId);

    List<Map<String, Object>> selectMyData(@Param("firstDay") String firstDay, @Param("lastDay") String lastDay, @Param("userId") Long userId);

    List<Map<String, Object>> selectReportByUser(@Param("startDate") String startDate, @Param("endDate") String endDate, @Param("userId") Long userId);

    List<TbDailyReport> getReportListByProject(@Param("userName") String userName, @Param("projectId") Long projectId, @Param("reportDate") String reportDate);

    List<TbUserDailyReport> getMyReportListByDate(@Param("userId") Long userId, @Param("startDate") String startDate, @Param("endDate") String endDate);

    List<TbDailyReportAnnotate> getAnnotateListByReport(Long reportId);
}
